package edu.maplef.bookwild.dao.impl.jdo;

import com.xiaonei.api.schema.Friend;

import edu.maplef.bookwild.dao.IBuddyDao;
import edu.maplef.bookwild.schema.Buddy;

public class BuddyDaoJDOImpl extends BaseDaoJDOImpl<Buddy> implements IBuddyDao {

	@Override
	public Buddy Friend2Buddy(Friend friend) throws Exception {
		Buddy b;
		try {
			b = new Buddy(friend.getId());
			b.setName(friend.getName());
			b.setHeadurl(friend.getHeadurl());
		} catch (Exception e) {
			throw e;
		}
		return b;
	}
}
